package com.qijian.business.domain.query;

import java.math.BigDecimal;

import com.qijian.common.utils.mybatis.WhereType;
import com.qijian.common.utils.mybatis.WhereTypeEnum;
import lombok.Data;

import java.util.List;
import java.util.Set;

import lombok.ToString;
import com.baomidou.mybatisplus.annotation.TableName;


/**
 * 供应商库存对象 查询条件类
 *
 * @author qijian
 * @date 2024-06-12
 */

@Data
@ToString
@TableName("supplier_inventory")
public class SupplierInventoryQuery {

    @WhereType(filed = "id")
    private Long id;
    @WhereType(filed = "id", type = WhereTypeEnum.IN)
    private Set<Long> ids;
    @WhereType(filed = "supplier_id")
    private Long supplierId;

    @WhereType(filed = "supplier_name", type = WhereTypeEnum.LIKE)
    private String supplierName;
    @WhereType(filed = "item_id")
    private Long itemId;
    @WhereType(filed = "item_name", type = WhereTypeEnum.LIKE)
    private String itemName;
    @WhereType(filed = "item_code", type = WhereTypeEnum.LIKE)
    private String itemCode;
    @WhereType(filed = "item_attr", type = WhereTypeEnum.LIKE)
    private String itemAttr;
    @WhereType(filed = "item_unit", type = WhereTypeEnum.LIKE)
    private String itemUnit;
    @WhereType(filed = "item_unit_sup")
    private String itemUnitSup;
    @WhereType(filed = "quantity")
    private BigDecimal quantity;
    @WhereType(filed = "quantity_sup")
    private BigDecimal quantitySup;
    @WhereType(filed = "wx_code", type = WhereTypeEnum.LIKE)
    private String wxCode;
    @WhereType(filed = "process_id")
    private Long processId;
    @WhereType(filed = "remark")
    private String remark;
    @WhereType(filed = "process_name", type = WhereTypeEnum.LIKE)
    private String processName;
    @WhereType(filed = "data_type")
    private Long dataType;
    @WhereType(filed = "draw_no", type = WhereTypeEnum.LIKE)
    private String drawNo;
    @WhereType(filed = "part_no", type = WhereTypeEnum.LIKE)
    private String partNo;

    @WhereType(filed = "project_machine_no", type = WhereTypeEnum.LIKE)
    private String projectMachineNo;

    @WhereType(func = "(supplier_inventory.quantity > 0 OR supplier_inventory.quantity_sup > 0)")
    private Boolean check;

    @WhereType(filed = "item_code", type = WhereTypeEnum.IN)
    private List<String> itemCodeList;

    @WhereType(filed = "project_machine_no", type = WhereTypeEnum.IN)
    private List<String> projectMachineNoList;

    @WhereType(ignore = true)
    private List<String> wxCodeList;
}
